namespace YAF.Classes.Core
{
    using System;
    using YAF.Classes.Util;

    public class AdminPage : ForumPage
    {
        public AdminPage()
            : this(null)
        {
 
        }

        public AdminPage(string transPage)
            : base(transPage)
        {
            _isAdminPage = true;
            Load += AdminPage_Load;
        }

        private void AdminPage_Load(object sender, EventArgs e)
        {
            if (!PageContext.IsAdmin)
            {
                YafBuildLink.AccessDenied();
            }
        }
    }
}
